<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<!doctype html>
<html class="no-js">

<head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="description" content="">
    <meta name="keywords" content="">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
    <title>沃店</title>
    <!-- Set render engine for 360 browser -->
    <meta name="renderer" content="webkit">
    <!-- No Baidu Siteapp-->
    <meta http-equiv="Cache-Control" content="no-siteapp"/>

    <!-- Add to homescreen for Chrome on Android -->
    <meta name="mobile-web-app-capable" content="yes">

    <!-- Add to homescreen for Safari on iOS -->
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <meta name="apple-mobile-web-app-title" content="Amaze UI"/>

    <link rel="stylesheet" href="${pageContext.request.contextPath}/assets/css/amazeui.min.css">
    <link rel="stylesheet" href="${pageContext.request.contextPath}/assets/css/app.css">
    <link rel="stylesheet" href="${pageContext.request.contextPath}/assets/css/index.css">
    <!--必要样式-->
    <style type="text/css">
        .menuItem img {
            width: 100%;
        }

        body {
            background: url(${pageContext.request.contextPath}/images/qrcode_bg.png) no-repeat;
            background-size: 100% 100%;
        }

    </style>
</head>

<body>
<div style="width: 100%" align="center">
<img id="qrcode" align="center" src="" style="margin-top:50px;width:260px;height: 260px; ">
</div>
    <%--<div id="doc-qrcode" align="center" style="margin-top: 70px;">--%>
<%--</div>--%>

<script src="${pageContext.request.contextPath}/assets/js/jquery.min.js"></script>
<script src="${pageContext.request.contextPath}/assets/js/amazeui.min.js"></script>
<script type="text/javascript">
    $(function () {
        /*
         $.ajax({
         type: "get",
         url: '{pageContext.request.contextPath}/clientUser/getQrcode',
         dataType: 'json',
         success: function (data) {
         if (data.code == 200) {

         $('#doc-qrcode').empty().qrcode(data.obj);
         }
         }

         });
         */
        $.ajax({
            type: "get",
            url: '${pageContext.request.contextPath}/clientUser/qrcode',
            dataType: 'json',
            success: function (data) {
                if (data.ticket != null) {
                    $('#qrcode').attr('src', 'https://mp.weixin.qq.com/cgi-bin/showqrcode?ticket=' + data.ticket);
                }
            }

        });


    });

</script>
</body>

</html>
